﻿using System.Web.Mvc;
using Eacademy.Library.Routes;

namespace Eacademy.Areas.Mentor
{
    public class MentorAreaRegistration : AreaRegistration
    {
        public override string AreaName
        {
            get
            {
                return "Mentor";
            }
        }

        public override void RegisterArea(AreaRegistrationContext context)
        {
            context.MapRouteLowerCase(
                "Mentor_lessons",
                "Mentor/Lessons/List/{id}",
                new { area = "Mentor", action = "Index", controller = "Lessons", id = UrlParameter.Optional },
                new string[] { "Eacademy.Areas.Mentor.Controllers" }
            );

            context.MapRouteLowerCase(
                "Mentor Assignments",
                "Mentor/Assignments/List/{id}",
                new { area = "Mentor", action = "Index", controller = "Assignments", id = UrlParameter.Optional },
                new string[] { "Eacademy.Areas.Mentor.Controllers" }

            );

            context.MapRouteLowerCase(
                "Mentor_default",
                "Mentor/{controller}/{action}/{id}",
                new { area = "Mentor", controller = "Subjects", action ="Index", id = UrlParameter.Optional },
                new string[] { "Eacademy.Areas.Mentor.Controllers" }

            );
        }
    }
}
